<template>
 <div>
   <h1>热门新闻</h1>
   <div>{{num}}</div>
   <div>
     <button @click="num++">+</button>
   </div>
 </div>
  
</template>

<script>
export default {
  data(){
    return{
      num:0
    }
  },
  beforeCreate(){
    console.log('------热门新闻beforeCreate--------');
  },
  created(){
    console.log('------热门新闻created--------');
  },
  beforeMount(){
     console.log('------热门新闻beforeMount--------');
  },
  mounted(){
     console.log('------热门新闻mounted--------');
  },
  beforeDestroy(){
    console.log('------热门新闻beforeDestroy--------');
  },
  destroyed(){
    console.log('------热门新闻destroyed--------');
  },
  activated(){
     console.log('------热门新闻activated-------');
  },
  deactivated(){
    console.log('------热门新闻deactivated-------');
  }
}
</script>

<style>

</style>